import os
import time

NowTime = time.localtime()
NowTimeH = NowTime.tm_hour
NowTimeM = NowTime.tm_min

if NowTimeH > 23 & NowTimeH < 6:
    if NowTimeM >30:
        os.system('shutdown /s /t 10 /c "太晚啦，关电脑睡觉！"')
